<template>
	<view>
		<view style="background: url(https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20230411/e63bcf73858e37c567847ca55821ddfa.png) no-repeat;background-size: 100%;width: 100%;height: 414rpx;">

		</view>
		<view style="width: 92%;position: absolute;top:10rpx;left: 4%;padding-bottom: 30rpx;">
			<view style="position: relative;">
				<input type="text"   class="sou" placeholder-class="suo" v-model="keywords"
					placeholder="找人/找货/搜信息" confirm-type="search" @confirm="search" />
				<image src="https://dyeego.oss-cn-beijing.aliyuncs.com/uploads/20220325/91243acc628efa1338d3d38826d22484.png"
					class="souicon" mode=""></image>
			</view>
			<!-- <view v-if="lishi_list.length>0" style="width: 92%;margin: 20rpx auto;">
				<view style="line-height: 80rpx;font-size: 28rpx;color:#fff;overflow: hidden;">
					搜索历史
					<text @click="qingkong" style="float: right;font-size: 24rpx;">清空搜索历史</text>
				</view>
				<view style="overflow: hidden;line-height: 40rpx;">
					<text @click="sou_ls(item.text)" v-for="(item,index) in lishi_list" :key='index' style="float: left;color: #666;font-size: 24rpx;padding: 0 10rpx;background-color:#eee;margin: 4rpx;border-radius: 20rpx;">{{item.text}}</text>
				</view>
			</view> -->
			<!-- <view class="tuijian">
				<view :class="type==1?'active_type':'a_type'" @click="qie(1)">
					产品
				</view>
				<view :class="type==2?'active_type':'a_type'" @click="qie(2)">
					企业
				</view>
				<view :class="type==3?'active_type':'a_type'" @click="qie(3)">
					期货
				</view>
				<view :class="type==4?'active_type':'a_type'" @click="qie(4)">
					用户
				</view>
			</view> -->
			<!-- 产品 -->
			<view v-if="type==1">
				<view v-if="xianshi" style="margin:10rpx 0 10rpx;">
					<!-- <vgt-tab
						class="tab-xxx"
						:list="list"
						:defaultChoseInd="100"
						defaultChoseItem=""
						@onValueChange="handleValueChange"
					/> -->
					<scroll-view id="tab-bar" class="scroll-h" :scroll-x="true" :show-scrollbar="false" :scroll-into-view="scrollInto">
							<view v-for="(tab,index) in yuan_list" :key="tab.id" class="uni-tab-item" :id="tab.ids" :data-current="index" @click="ontabtap(index)">
							    <text class="uni-tab-item-title" :class="tabIndex==index ? 'uni-tab-item-title-active' : ''">{{tab.name}}</text>
								<image v-if="tabIndex==index" src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20230411/2176b3fec852179c4610f402fdac0589.png" style="width: 100rpx;height: 12rpx;position: absolute;left: 50%;bottom: 16rpx;transform: translateX(-50%);"  mode=""></image>
							</view>
					</scroll-view>
				</view>
				<!-- <view v-for="(item,index) in cp_list" :key='index' style="box-sizing: border-box;padding: 30rpx;background-color: #FFFFFF;margin-top: 26rpx;border-radius: 12rpx;">
					<view  @click="wzxq(item.id)">
						<view style="overflow: hidden;">
							<view style="width: 18%;float: left;overflow: hidden;">
								<image :src="item.user.avatar" style="width: 92rpx;height: 92rpx;border-radius: 50%;display: block;" mode=""></image>
							</view>
							<view style="width: 82%;float: left;padding: 6rpx 0;">
								<view style="height: 40rpx;line-height: 40rpx;">
									<text style="color: #000000;font-size: 30rpx;display: inline-block;width: 200rpx;font-weight: 600;" class="yihang">{{item.user.nickname}}</text>
									<text style="color: #999999;font-size: 24rpx;float: right;">发布于 {{item.create_time}}</text>
								</view>
								<view style="height: 40rpx;line-height: 40rpx;color: #999999;font-size: 24rpx;" class="yihang">
									{{item.user.company || ''}}
								</view>
							</view>
						</view>
						<view style="line-height: 60rpx;color: #000000;font-size: 30rpx;margin-top: 30rpx;font-weight: 600;">
							{{item.main_content}}
						</view>
						<view style="overflow: hidden;margin-top: 20rpx;" class="tu" v-if="item.main_images">
							<view v-for="(a,b) in item.main_images" :key='b' style="width: 190rpx;height: 190rpx;float: left;border-radius: 16rpx;overflow: hidden;">
								<image :src="a" style="width: 100%;height: 100%;left: 0;" mode="aspectFill"></image>
							</view>

						</view>
					</view>

					<view style="line-height: 80rpx;display: flex;">
						<view style="flex: 1;color: #999999;font-size: 24rpx;box-sizing: border-box;padding-left: 60rpx;position: relative;">
							<image src="@/static/index/icon_collect.png" style="width: 30rpx;height: 30rpx;position: absolute;top: 50%;left: 20rpx;transform: translateY(-50%);" mode=""></image>
							收藏({{item.collect_num}})

						</view>
						<view style="flex: 1;color: #999999;font-size: 24rpx;box-sizing: border-box;padding-left: 60rpx;position: relative;">
							<image src="@/static/index/icon_comment.png" style="width: 30rpx;height: 30rpx;position: absolute;top: 50%;left: 20rpx;transform: translateY(-50%);" mode=""></image>
							评论({{item.comment_num}})

						</view>
						<view style="flex: 1;color: #999999;font-size: 24rpx;box-sizing: border-box;padding-left: 60rpx;position: relative;">
							<image src="@/static/index/icon_like.png" style="width: 30rpx;height: 30rpx;position: absolute;top: 50%;left: 20rpx;transform: translateY(-50%);" mode=""></image>
							点赞({{item.like_num}})

						</view>
						<view @click="lahei(item.user_id,index)"
							style="flex: 1;color: #C0C0C0;font-size: 20rpx;box-sizing: border-box;text-align: right;">
							<text class="iconfont icon-guanbi" style="font-size: 24rpx;"></text>
						</view>
					</view>
				</view> -->


				<view v-for="(item,index) in cp_list" :key='index' style="width: 100%;margin: 20rpx auto;padding: 30rpx;box-sizing: border-box;border-radius:16rpx;background-color: #FFFFFF;">
					<view style="overflow: hidden;">
						<view @click="yh_xx(item.user_id,item.type,item.firm_id)" style="width: 80rpx;height: 80rpx;float: left;margin-right: 30rpx;position: relative;">
							<image :src="item.user.avatar" style="width: 80rpx;height: 80rpx;display: block;border-radius: 12upx;overflow: hidden;"
								mode=""></image>
								<!-- vip -->
							<image v-if="item.user.is_vip==1 && item.type==2"
								src="https://frozen-info.oss-cn-shanghai.aliyuncs.com/uploads/miniapp/ren.png" style="width: 30rpx;height: 30rpx;position: absolute;right: -10rpx;bottom: -10rpx;z-index: 4;"
								mode=""></image>
								<!-- 个人 -->
							<image v-if="item.user.is_vip==2 && item.type==2"
								src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20220616/ce4d9a4e5c9d814d939dc3324abc44d6.png" style="width: 30rpx;height: 30rpx;position: absolute;right: -10rpx;bottom: -10rpx;z-index: 4;"
								mode=""></image>
								<!-- 企业 -->
							<image v-if="item.type==1"
								src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20220616/daf7dad493b169a57961fac90302d9be.png" style="width: 30rpx;height: 30rpx;position: absolute;right: -10rpx;bottom: -10rpx;z-index: 4;"
								mode=""></image>
						</view>
						<view style="width: 72%;float: left;">
							<view @click="yh_xx(item.user_id,item.type,item.firm_id)" style="line-height: 50rpx;overflow: hidden;">
								<text v-if="item.user.is_vip==2" style="color: #2B85E4;font-size: 30rpx;display: block;max-width: 300rpx;float: left;"
									class="yihang">
									<text v-if="item.user.remark_name!=''">{{item.user.remark_name || ''}}</text>
									<!-- <text v-if="item.user.remark_name!=''" style="margin-left: 10rpx;font-size: 26rpx;">{{item.user.name || ''}}</text> -->
									<text v-if="item.user.remark_name==''">{{item.user.name || ''}}</text>

									</text>
								<text v-if="item.user.is_vip==1" style="color: #F29100;font-size: 30rpx;display: block;max-width: 300rpx;float: left;font-weight: 600;"
									class="yihang">
									<text v-if="item.user.remark_name!=''">{{item.user.remark_name || ''}}</text>
									<!-- <text v-if="item.user.remark_name!=''" style="margin-left: 10rpx;font-size: 26rpx;">{{item.user.name || ''}}</text> -->
									<text v-if="item.user.remark_name==''">{{item.user.name || ''}}</text>

									</text>
							<!-- 	<image @click="yonghu_xx(item.user_id)"
									src="https://frozen-info.oss-cn-shanghai.aliyuncs.com/uploads/miniapp/shenfen.png" style="width: 28rpx;height: 22rpx;float: left;margin-top: 14rpx;margin-left: 20rpx;"
									mode=""></image> -->
							</view>
							<!-- 个人 -->
							<view v-if="item.type==2" style="line-height: 30rpx;font-size: 24rpx;margin-top: 10rpx;">
								<text v-if="item.user.firm_check==1" style="border-radius: 10rpx;background: linear-gradient(0deg, #1fb0ac 0%, #5EC4C2 100%);border-radius: 6rpx;color: #FEFEFE;font-size: 20rpx;padding: 0rpx 10rpx;float: left;margin-right: 10rpx;">
									已认证
								</text>
								<text v-if="item.user.company!=''">{{item.user.company || ''}}</text>
								<text v-if="item.user.position!=''" style="margin-left: 20rpx;">{{item.user.position || ''}}</text>
							</view>
							<!-- 企业 -->
							<view v-if="item.type==1" style="line-height: 30rpx;font-size: 24rpx;margin-top: 10rpx;">
								<text v-if="item.user.firm_check==1" style="border-radius: 10rpx;background: linear-gradient(0deg, #1fb0ac 0%, #5EC4C2 100%);border-radius: 6rpx;color: #FEFEFE;font-size: 20rpx;padding: 0rpx 10rpx;float: left;margin-right: 10rpx;">
									已认证
								</text>
								<text v-if="item.user.user_nickname!=''">{{item.user.user_nickname || ''}}</text>
								<text v-if="item.user.user_position!=''" style="margin-left: 20rpx;">{{item.user.user_position || ''}}</text>

							</view>
							<view style="overflow: hidden;margin-top: 10rpx;">
								<text class="xiao" style="color: red;" v-if="item.is_top==1">置顶</text>
								<text v-if="item.tips_manage.length>0" v-for="(a,b) in item.tips_manage" :key='b' class="xiao">{{a.name}}</text>
							</view>
							<!-- <view style="height: 30rpx;line-height: 30rpx;color: #999999;font-size: 24rpx;"
								class="yihang">
								{{item.user.company || ''}}
							</view> -->
						</view>
						<view style="width: 10%;float: left;position: relative;" @click="lahei(item.user_id,index)">
							<text class="iconfont icon-guanbi" style="font-size: 24rpx;position: absolute;top: 20rpx;right: 0;"></text>
						</view>
					</view>
					<view @click="wzxq(item.id)" style="color: #000000;font-size: 28rpx;line-height: 40rpx;margin: 16rpx 0 0;">
						<!-- <view class="sanhang">{{item.main_content}}</view> -->
						<view class="sihang">
							<text>{{item.main_content || ''}}</text>
						</view>
						<view v-if="item.more_check" style="line-height: 40rpx;color: #1fb0ac;font-size: 26rpx;">
							查看更多>
						</view>
					</view>
					<view @click="wzxq(item.id)"  style="overflow: hidden;" class="tu">
						<view v-for="(a,b) in item.main_images" :key='index' style="width: 190rpx;height: 190rpx;float: left;border-radius: 16rpx;overflow: hidden;">
							<image :src="a" style="width: 100%;height: 100%;left: 0;" mode="aspectFill"></image>
						</view>

					</view>
					<view v-if="item.city!=''" class="" style="line-height: 40rpx;overflow: hidden;">
						<image src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20230613/bc4b7edcf33b26f93cf7d5c8406eb52a.png" style="width: 40rpx;height: 40rpx;display: block;float: left;margin-top: 10rpx;" mode=""></image>
						<text style="margin-left: 6rpx;display: inline-block;max-width: 500rpx;float: left;color: #999999;font-size: 26rpx;line-height: 60rpx;" class="yihang">{{item.city || ''}}</text>
					</view>
					<view @click="wzxq(item.id)" style="overflow: hidden;margin: 20rpx 0 0;">
						<text
							style="color: #999999;font-size: 26rpx;float: left;display: block;max-width: 280rpx;line-height: 60rpx;">{{item.create_time}}</text>

						<view style="float: right;line-height: 60rpx;">
							<image
								src="@/static/index/icon_collect.png"
								style="width: 36rpx;height: 36rpx;float: left;margin-top: 12rpx;margin-right: 6rpx;" mode=""></image>
							<text style="color: #000000;font-size: 24rpx;float: left;margin-right: 14rpx;">
								{{item.collect_num>10000?( (item.collect_num/10000).toFixed(1)+'万' ):item.collect_num || 0}}
							</text>
						</view>
						<view style="float: right;line-height: 60rpx;margin-right: 10rpx;">
							<image
								src="@/static/index/icon_comment.png"
								style="width: 36rpx;height: 36rpx;float: left;margin-top: 12rpx;margin-right: 6rpx;" mode=""></image>
							<text style="color: #000000;font-size: 24rpx;float: left;margin-right: 14rpx;">
								{{item.comment_num>10000?( (item.comment_num/10000).toFixed(1)+'万' ):item.comment_num || 0}}
							</text>
						</view>
						<view style="float: right;line-height: 60rpx;margin-right: 10rpx;">
							<image
								src="@/static/index/icon_like.png"
								style="width: 36rpx;height: 36rpx;float: left;margin-top: 12rpx;margin-right: 6rpx;" mode=""></image>
							<text style="color: #000000;font-size: 24rpx;float: left;margin-right: 14rpx;">
								{{item.like_num>10000?( (item.like_num/10000).toFixed(1)+'万' ):item.like_num || 0}}
							</text>
						</view>

					</view>

				</view>


				<view v-if="xianshi">
					<view v-if="cp_kk" style="text-align: center;">
						<image src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20220329/e86889a9b8fd67d8950e4775d67316c.png" style="width: 400rpx;" mode="widthFix"></image>
					</view>
					<u-divider color='#717171' bg-color='#f0f2f8' height='80' border-color='#717171' text="暂无数据" v-if="cp_list.length==0"></u-divider>
					<u-divider color='#717171' bg-color='#f0f2f8' height='80' border-color='#717171' text="没有更多了" v-if="cp_list.length>0 && cp_enmpy"></u-divider>
				</view>
				<view v-if="!xianshi">
					<view style="text-align: center;">
						<image src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20220329/e86889a9b8fd67d8950e4775d67316c.png" style="width: 400rpx;" mode="widthFix"></image>
					</view>
					<u-divider color='#717171' bg-color='#f0f2f8' height='80' border-color='#717171' text="暂无数据" ></u-divider>

				</view>
			</view>
			<!-- 企业 -->
			<view v-if="type==2">
				<view style="width:100%;margin: 26rpx auto;display: flex;">
					<view  @click="jiage(1)" :class="tui_type==1?'tui_active':'tui_mei'" style="flex: 1;text-align: center;">
						全部
					</view>
					<!-- <view  @click="jiage(2)" :class="tui_type==2?'tui_active':'tui_mei'" style="flex: 1;text-align: center;">

						<text v-if="label2.length<=4">{{label2 || '位置'}}</text>
						<text v-if="label2.length>4">{{label2.slice(0,4)+'...' || '位置'}}</text>
						<text class="iconfont icon-xiangxia" style="font-size: 22rpx;"></text>
					</view> -->
					<view  @click="jiage(3)" :class="tui_type==3?'tui_active':'tui_mei'" style="flex: 1;text-align: center;">
						<!-- {{qihuo3 || '市场'}} -->
						<text v-if="qihuo3.length<=4">{{qihuo3 || '市场'}}</text>
						<text v-if="qihuo3.length>4">{{qihuo3.slice(0,4)+'...' || '市场'}}</text>
						<text class="iconfont icon-xiangxia" style="font-size: 22rpx;"></text>
					</view>
					<view  @click="jiage(5)" :class="tui_type==5?'tui_active':'tui_mei'" style="flex: 1;text-align: center;">
						<!-- {{qihuo5 || '类型'}} -->
						<text v-if="qihuo6.length<=4">{{qihuo6 || '品类'}}</text>
						<text v-if="qihuo6.length>4">{{qihuo6.slice(0,4)+'...' || '品类'}}</text>
						<text class="iconfont icon-xiangxia" style="font-size: 22rpx;"></text>
					</view>
					<view  @click="jiage(4)" :class="tui_type==4?'tui_active':'tui_mei'" style="flex: 1;text-align: center;">
						<!-- {{qihuo5 || '类型'}} -->
						<text v-if="qihuo5.length<=4">{{qihuo5 || '类型'}}</text>
						<text v-if="qihuo5.length>4">{{qihuo5.slice(0,4)+'...' || '类型'}}</text>
						<text class="iconfont icon-xiangxia" style="font-size: 22rpx;"></text>
					</view>

				</view>
				<view v-for="(item,index) in qiye_list" :key='index'>
					<view v-if="item.special_manage==1" style="box-sizing: border-box;padding: 30rpx 30rpx 0;background-color: #FFFFFF;margin-top: 26rpx;border-radius: 16rpx;" >
						<view @click="qyxq(item.id,item.special_manage)" style="overflow: hidden;">
							<view style="width: 35%;float: left;position: relative;">
								<image :src="item.logo_image" style="width: 190rpx;height: 190rpx;display: block;border-radius: 10rpx;" mode=""></image>

							</view>
							<view style="width: 65%;float: left;padding: 6rpx 0;">
								<view style="line-height: 40rpx;color: #010101;font-size: 32rpx;margin: 10rpx 0;"
									class="yihang">
									{{item.name}}
								</view>
								<view style="line-height: 40rpx;color: #010101;font-size: 32rpx;margin: 10rpx 0;overflow: hidden;">
									<text v-for="(a,b) in item.client_position_arr" :key='b' style="margin-bottom: 10rpx;background: linear-gradient(0deg, #1fb0ac 0%, #5EC4C2 100%);border-radius: 6rpx;color: #FEFEFE;font-size: 22rpx;padding: 0rpx 10rpx;float: left;margin-right: 10rpx;">
										{{a.title || ''}}
									</text>
								</view>
								<view style="line-height: 30rpx;color: #999999;font-size: 22rpx;margin: 10rpx 0 20rpx;" class="yihang">
									主营：{{item.manage_category}}
								</view>
								<view style="line-height: 30rpx;color: #999999;font-size: 22rpx;" class="erhang">
									<!-- <text class="iconfont icon-dizhi2"
										style="color: #909193;font-size: 24rpx;"></text> -->
									入驻市场：暂无市场
								</view>
							</view>
						</view>
						<view style="display: flex;text-align: center;color: #999999;font-size: 22rpx;line-height: 100rpx;">
							<view style="flex: 2;text-align: left;">
								浏览量：{{item.views_num}}
							</view>
							<view style="flex: 2;text-align: left;">
								关注数：{{item.attention_num}}人
							</view>
							<view style="flex: 2;">
								联系次数：{{item.contact_num || 0}}次
							</view>
							<view @click="lahei1(item.id,index)" style="flex: 1;text-align: right;">
								<text class="iconfont icon-guanbi" style="font-size: 24rpx;"></text>
							</view>
						</view>
					</view>
					<view v-if="item.special_manage==2" style="box-sizing: border-box;padding: 30rpx 30rpx 0;background-color: #FFFFFF;margin-top: 26rpx;border-radius: 16rpx;">
						<view style="overflow: hidden;" @click="qyxq(item.id,item.special_manage)">
							<view style="width: 35%;float: left;position: relative;">
								<image :src="item.logo_image"
									style="width: 190rpx;height: 190rpx;display: block;border-radius: 20rpx;" mode=""></image>
							</view>
							<view style="width: 65%;float: left;padding: 6rpx 0;">
								<view style="line-height: 40rpx;color: #010101;font-size: 32rpx;margin: 10rpx 0;"
									class="yihang">
									{{item.name}}
								</view>
								<view style="line-height: 40rpx;color: #010101;font-size: 32rpx;margin: 10rpx 0;overflow: hidden;">
									<text v-for="(a,b) in item.client_position_arr" :key='b' style="margin-bottom: 10rpx;background: linear-gradient(0deg, #1fb0ac 0%, #5EC4C2 100%);border-radius: 6rpx;color: #FEFEFE;font-size: 22rpx;padding: 0rpx 10rpx;float: left;margin-right: 10rpx;">
										{{a.title || ''}}
									</text>
								</view>
								<view style="overflow: hidden;line-height: 30rpx;margin: 10rpx 0;">
									<view style="width: 10%;float: left;">
										<image
											src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20220329/%E5%9B%BE%E5%B1%82%20564%402x.png"
											style="width: 30rpx;height: 30rpx;" mode=""></image>
									</view>
									<view style="color: #333333;font-size: 22rpx;width: 90%;float: left;">
										{{item.wl_address_text || ''}}
									</view>
								</view>
								<view style="overflow: hidden;line-height: 30rpx;">
									<view style="width: 10%;float: left;">
										<image
											src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20220329/%E5%9B%BE%E5%B1%82%20565%402x.png"
											style="width: 30rpx;height: 30rpx;" mode=""></image>
									</view>
									<view style="color: #333333;font-size: 22rpx;width: 90%;float: left;">
										{{item.wl_main_text || ''}}
									</view>
								</view>
							</view>
						</view>
						<view style="display: flex;text-align: center;color: #999999;font-size: 22rpx;line-height: 100rpx;">
							<view style="flex: 2;text-align: left;">
								浏览量：{{item.views_num}}
							</view>
							<view style="flex: 2;text-align: left;">
								关注数：{{item.contact_num}}人
							</view>
							<view style="flex: 2;">
								联系次数：{{item.attention_num}}次
							</view>
							<view @click="lahei1(item.id,index)" style="flex: 1;text-align: right;">
								<text class="iconfont icon-guanbi" style="font-size: 24rpx;"></text>
							</view>
						</view>
					</view>
					<view v-if="item.special_manage==3"  style="box-sizing: border-box;padding: 30rpx 30rpx 0;background-color: #FFFFFF;margin-top: 26rpx;border-radius: 16rpx;">
						<view  style="overflow: hidden;" @click="qyxq(item.id,item.special_manage,item.name)">
							<view style="width: 35%;float: left;position: relative;">
								<image :src="item.logo_image"
									style="width: 190rpx;height: 190rpx;display: block;border-radius: 20rpx;"
									mode=""></image>

							</view>
							<view style="width: 65%;float: left;padding: 6rpx 0;">
								<view style="line-height: 40rpx;color: #010101;font-size: 32rpx;margin: 10rpx 0;"
									class="yihang">
									{{item.name}}
								</view>
								<view style="line-height: 40rpx;color: #010101;font-size: 32rpx;margin: 10rpx 0;overflow: hidden;">
									<text v-for="(a,b) in item.client_position_arr" :key='b' style="margin-bottom: 10rpx;background: linear-gradient(0deg, #1fb0ac 0%, #5EC4C2 100%);border-radius: 6rpx;color: #FEFEFE;font-size: 22rpx;padding: 0rpx 10rpx;float: left;margin-right: 10rpx;">
										{{a.title || ''}}
									</text>
								</view>
								<view style="line-height: 30rpx;color: #999999;font-size: 22rpx;margin: 10rpx 0 20rpx;"
									class="erhang">
									生产品类：{{item.process_text || '暂无生产品类'}}
								</view>

							</view>
						</view>
						<view style="display: flex;text-align: center;color: #999999;font-size: 22rpx;line-height: 100rpx;">
							<view style="flex: 2;text-align: left;">
								浏览量：{{item.views_num || 0}}
							</view>
							<view style="flex: 2;text-align: left;">
								关注数：{{item.attention_num || 0}}人
							</view>
							<view style="flex: 2;">
								联系次数：{{item.contact_num || 0}}次
							</view>
							<view @click="lahei(item.id,index)" style="flex: 1;text-align: right;">
								<text class="iconfont icon-guanbi" style="font-size: 24rpx;"></text>
							</view>
						</view>
					</view>
				</view>
				<view v-if="qiye_kk" style="text-align: center;">
					<image src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20220329/e86889a9b8fd67d8950e4775d67316c.png" style="width: 400rpx;" mode="widthFix"></image>
				</view>
				<u-divider color='#717171' bg-color='#f0f2f8' height='80' border-color='#717171' text="暂无数据" v-if="qiye_list.length==0"></u-divider>
				<u-divider color='#717171' bg-color='#f0f2f8' height='80' border-color='#717171' text="没有更多了" v-if="qiye_list.length>0 && qiye_enmpy"></u-divider>
			</view>
			<!-- 期货 -->
			<view v-if="type==3">
				<view style="width:100%;margin: 26rpx auto;display: flex;justify-content:space-between;">
					<view  @click="qi_huo(1)" :class="qi_type==1?'tui_active':'tui_mei'">
						全部价格
					</view>
					<view  @click="qi_huo(2)" :class="qi_type==2?'tui_active':'tui_mei'">
						{{qihuo || '品牌规格'}}<text class="iconfont icon-xiangxia" style="font-size: 22rpx;"></text>
					</view>
					<view  @click="qi_huo(3)" :class="qi_type==3?'tui_active':'tui_mei'">
						{{qihuo1 || '产区'}}<text class="iconfont icon-xiangxia" style="font-size: 22rpx;"></text>
					</view>
					<view  @click="qi_huo(4)" :class="qi_type==4?'tui_active':'tui_mei'">
						{{qihuo2 || '厂号'}}<text class="iconfont icon-xiangxia" style="font-size: 22rpx;"></text>
					</view>
				</view>
				<view style="width: 100%;box-sizing: border-box;padding: 30rpx;background-color: #FFFFFF;border-radius: 16rpx;margin-bottom: 20rpx;" v-for="(item,index) in qhjy_list" :key='index'>
					<view @click="changjia(item.brand_id)" style="overflow: hidden;">
						<view style="width: 18%;float: left;overflow: hidden;">
							<image :src="item.brand_avatar" style="width: 92rpx;height: 92rpx;border-radius: 50%;display: block;" mode=""></image>
						</view>
						<view style="width: 82%;float: left;padding: 6rpx 0;">
							<view style="height: 40rpx;line-height: 40rpx;">
								<text style="color: #000000;font-size: 30rpx;display: inline-block;font-weight: 600;float: left;">{{item.brand_name}}</text>
								<image :src="item.place.logo_image" style="width: 32rpx;height: 20rpx;float: left;margin-top: 10rpx;margin-left: 20rpx;" mode=""></image>
								<text style="color: #999999;font-size: 20rpx;float: left;margin-left: 20rpx;">({{item.place.name}})</text>
								<text style="color: #999999;font-size: 24rpx;float: right;">{{item.create_time_tips}}</text>
							</view>
							<view style="height: 40rpx;line-height: 40rpx;color: #010101;font-size: 24rpx;" class="yihang">
								{{item.brand_en_name}} <text style="float: right;color: #999999;font-size: 24rpx;">发布于 {{item.create_time}}</text>
							</view>
						</view>
					</view>
					<view v-if="is_vip==2">
						<view v-html="item.en_content" style="color: #010101;font-size: 26rpx;margin-top: 20rpx;line-height: 40rpx;">

						</view>
						<view style="background-color: #eeeeee;box-sizing: border-box;padding: 20rpx;">
							<view v-html="item.cn_content">

							</view>
						</view>
					</view>
					<view v-if="is_vip==1">
						<view v-html="item.vip_en_content" style="color: #010101;font-size: 26rpx;margin-top: 20rpx;line-height: 40rpx;">

						</view>
						<view style="background-color: #eeeeee;box-sizing: border-box;padding: 20rpx;">
							<view v-html="item.vip_cn_content">

							</view>
						</view>
					</view>
					<view style="display: flex;margin-top: 20rpx;">
						<view style="flex: 1;">
							<view @click="dcjs(item.brand_id)" style="width: 100%;height: 60rpx;line-height: 60rpx;text-align: center;font-size: 24rpx;background-color: #C9E7E6;color: #1fb0ac;border-radius: 30rpx;">
								代采介绍

							</view>
						</view>
						<view @click="gz_cj(item.brand_id,index)" style="flex: 1;margin: 0 10rpx;">
							<view v-if="item.is_collect==1" style="width: 100%;height: 60rpx;line-height: 60rpx;text-align: center;font-size: 24rpx;background-color: #1fb0ac;color: #ffffff;border-radius: 30rpx;">
								取消关注
							</view>
							<view v-if="item.is_collect==2" style="width: 100%;height: 60rpx;line-height: 60rpx;text-align: center;font-size: 24rpx;background-color: #C9E7E6;color: #1fb0ac;border-radius: 30rpx;">
								关注厂家
							</view>
						</view>
						<view style="flex: 1;">
							<button type="default" open-type="contact" style="width: 100%;height: 60rpx;line-height: 60rpx;text-align: center;font-size: 24rpx;background-color: #1fb0ac;color: #ffffff;border-radius: 30rpx;">
								一键代采

							</button>
						</view>
					</view>
				</view>
				<view style="text-align: center;margin-top: 50rpx;">
					<image v-if="qh_kk" :src="require('@/static/my/no-data.png')" style="width: 334rpx;"  mode="widthFix"></image>
					<view v-if="qhjy_list.length==0" style="text-align: center;color: #999999;font-size: 30rpx;line-height: 60rpx;">
						暂无推荐价格
					</view>
					<u-divider color='#717171' bg-color='#f0f2f8' height='80' border-color='#717171' text="没有更多了" v-if="qhjy_list.length>0 && qh_enmpy"></u-divider>
				</view>
			</view>


			<!-- 用户 -->
			<view v-if="type==4" style="margin:26rpx auto 26rpx;">

				<!-- <view @click="fanwei" style="line-height: 100rpx;display: flex;">
					<view style="flex: 1;color: #ffffff;font-size: 26rpx;">
						经营范围
					</view>
					<view style="flex: 5;color: #ffffff;font-size: 28rpx;text-align: right;">
						{{jyfw || '请选择'}}<text class="iconfont icon-xiangyou" style="font-size: 28rpx;"></text>
					</view>
				</view> -->

				<view v-for="(item,index) in user_list" :key='index' style="overflow: hidden;background-color: #FFFFFF;box-sizing: border-box;padding: 30rpx;border-radius: 20rpx;margin-bottom: 20rpx;">
					<view @click="yonghu_xx(item.id)" style="width: 80%;float: left;overflow: hidden;">
						<view style="width: 22%;float: left;">
							<image :src="item.avatar" style="width: 88rpx;height: 88rpx;border-radius: 50%;display: block;" mode=""></image>
						</view>
						<view style="width: 77%;float: left;padding: 4rpx 0;">
							<view style="line-height: 40rpx;font-size: 30rpx;color: #000000;overflow: hidden;">
								<text style="display: inline-block;float: left;" v-if="item.remark_name!=''">{{item.remark_name || ''}}</text>
								<text v-if="item.remark_name!=''" style="margin-left: 10rpx;font-size: 26rpx;display: inline-block;float: left;">{{item.name || ''}}</text>
								<text style="display: inline-block;float: left;" v-if="item.remark_name==''">{{item.name || ''}}</text>
							</view>
							<view style="line-height: 40rpx;font-size: 24rpx;color: #999999;" class="yihang">
								{{item.company || ''}}
							</view>
						</view>
					</view>
					<view style="width: 20%;float: left;">
						<view v-if="item.is_attention==0" @click="guanzhu(item.id,index)" style="width:120rpx;height: 50rpx;line-height: 50rpx;text-align: center;border: 1px solid #1fb0ac;color: #1fb0ac;font-size: 22rpx;border-radius: 25rpx;float: right;margin-top: 15rpx;">
							关注
						</view>
						<view v-if="item.is_attention==1" @click="guanzhu(item.id,index)" style="width:120rpx;height: 50rpx;line-height: 50rpx;text-align: center;border: 1px solid #F0AD4E;color: #FFFFFF;font-size: 22rpx;border-radius: 25rpx;float: right;margin-top: 15rpx;background-color: #F0AD4E;">
							已关注
						</view>
					</view>
				</view>
				<view v-if="user_kk" style="text-align: center;">
					<image src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20220329/e86889a9b8fd67d8950e4775d67316c.png" style="width: 400rpx;" mode="widthFix"></image>
				</view>
				<u-divider color='#717171' bg-color='#f0f2f8' height='80' border-color='#717171' text="暂无数据" v-if="user_list.length==0"></u-divider>
				<u-divider color='#717171' bg-color='#f0f2f8' height='80' border-color='#717171' text="没有更多了" v-if="user_list.length>0 && user_enmpy"></u-divider>
			</view>
		</view>


		<!-- 企业 -->
		<lb-picker ref="picker3" v-model="qihuo3" mode="selector" :dataset="{ name: qihuo3 }" :list="list_arr3"
			@confirm="handleConfirm3">
		</lb-picker>
		<lb-picker ref="picker5" v-model="qihuo5" mode="selector" :dataset="{ name: qihuo5 }" :list="list_arr5"
			@confirm="handleConfirm5">
		</lb-picker>
		<lb-picker ref="picker7" v-model="qihuo6" mode="selector" :dataset="{ name: qihuo6 }" :list="list_arr6"
			@confirm="handleConfirm6">
		</lb-picker>
		<lb-picker ref="picker6"
		  v-model="value2"
		  mode="multiSelector"
		  :list="list1"
		  :level="2"
		  :dataset="{ name: 'label2' }"
		  @confirm="handleConfirm4">
		</lb-picker>


		<!-- 期货交易 -->
		<lb-picker ref="picker" v-model="qihuo" mode="selector" :dataset="{ name: qihuo }" :list="list_arr"
			@confirm="handleConfirm">
		</lb-picker>
		<lb-picker ref="picker1" v-model="qihuo1" mode="selector" :dataset="{ name: qihuo1 }" :list="list_arr1"
			@confirm="handleConfirm1">
		</lb-picker>
		<lb-picker ref="picker2" v-model="qihuo2" mode="selector" :dataset="{ name: qihuo2 }" :list="list_arr2"
			@confirm="handleConfirm2">
		</lb-picker>

		<uni-popup id="popup" ref="popup2" :type="type_status" :animation="true">
			<view class="" style="background-color: #FFFFFF;padding:30upx;border-radius: 20upx;width: 500rpx;">
				<!-- <view @click="bgxq" style="line-height: 80rpx;color: #333333;font-size: 26rpx;overflow: hidden;border-bottom: 1px solid #eeeeee;">
					<image src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20220609/830b561ca7ce34b5f0558b840716b396.png" style="width: 30rpx;height: 30rpx;float: left;margin-top: 25rpx;" mode=""></image>
					<text style="float: left;margin-left: 20rpx;">不感兴趣</text>
				</view> -->
				<view @click="lhftr" style="line-height: 80rpx;color: #333333;font-size: 26rpx;overflow: hidden;">
					<image src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20220609/dc135c36cb2641ef2acffca98da776e0.png" style="width: 30rpx;height: 30rpx;float: left;margin-top: 25rpx;" mode=""></image>
					<text style="float: left;margin-left: 20rpx;">拉黑发帖人</text>
				</view>
			</view>
		</uni-popup>

		<uni-popup id="popup" ref="popup3" :type="type_status" :animation="true">
			<view class="" style="background-color: #FFFFFF;padding:30upx;border-radius: 20upx;width: 500rpx;">
				<!-- <view @click="bgxq1" style="line-height: 80rpx;color: #333333;font-size: 26rpx;overflow: hidden;border-bottom: 1px solid #eeeeee;">
					<image src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20220609/830b561ca7ce34b5f0558b840716b396.png" style="width: 30rpx;height: 30rpx;float: left;margin-top: 25rpx;" mode=""></image>
					<text style="float: left;margin-left: 20rpx;">不感兴趣</text>
				</view> -->
				<view @click="lhftr1" style="line-height: 80rpx;color: #333333;font-size: 26rpx;overflow: hidden;">
					<image src="https://static-1310167831.cos.ap-nanjing.myqcloud.com/uploads/20220609/dc135c36cb2641ef2acffca98da776e0.png" style="width: 30rpx;height: 30rpx;float: left;margin-top: 25rpx;" mode=""></image>
					<text style="float: left;margin-left: 20rpx;">拉黑该企业</text>
				</view>
			</view>
		</uni-popup>
    <noLoginToast ref="noLoginToast" />

	</view>
</template>

<script>
	import LbPicker from '@/components/lb-picker'
	import areaData from '@/sub/pages/area-data-min.js'
	import vgtTab from '@/components/vgt-tab.vue'
	export default {
		components: {
			vgtTab,
			LbPicker
		},
		data(){
			return{
				type:1,
				// list: [],
				tabIndex:0,
				scrollInto:'',
				yuan_list:[],
				tui_type:1,
				qi_type:1,
				keywords:'',
				category_id:'',
				index:'',


				// 产品
				cp_page:1,
				cp_list:[],
				cp_kk:false,
				cp_enmpy:false,


				// 企业
				qihuo3:'',
				province:'',
				city:'',
				list_arr3:[],
				yuan_list_arr3:[],
				qihuo5:'',
				list_arr5:[],
				yuan_list_arr5:[],
				category_id:'',
				qihuo6:'',
				list_arr6:[],
				yuan_list_arr6:[],
				value2: [],
				label2: '',
				list1: areaData,
				qiye_enmpy:false,
				qiye_kk:false,
				qiye_page:1,
				qiye_list:[],
				leixing:'',
				bazaar_id:'',


				// 期货
				qihuo:'',
				list_arr:[],
				yuan_list_arr:[],
				qihuo1:'',
				list_arr1:[],
				yuan_list_arr1:[],
				qihuo2:'',
				list_arr2:[],
				yuan_list_arr2:[],
				qh_enmpy:false,
				qh_kk:false,
				qhjy_list:[],
				qhjy_page:1,
				craft_ids:'',
				place_ids:'',
				specification_ids:'',
				manage_category_ids:'',
				brand_id:false,
				is_vip:2,

				// 用戶
				zhong1:'',
				zhong2:'',
				zhong3:'',
				manage_id:'',
				jyfw:'',
				user_page:1,
				user_list:[],
				user_kk:false,
				user_enmpy:false,
				type_status:'center',
				lh_id:'',
				lh_index:'',
				lh_id1:'',
				lh_index1:'',
				lishi_list:[],
				xianshi:false
			}
		},
		onLoad(option) {
			this.sou_lishi()
			// console.log(option,1111111444)
			this.userinfo()
			this.tz_fl()
			this.keywords=option.keywords
			// this.index=option.index
			// if(option.index==1 && option.type==1){
			// 	this.type=1
			// }else if(option.index==1 && option.type==2){
			// 	this.type=3
			// }else if(option.index==2 &&option.type==1){
			// 	this.type=2
			// 	this.province=option.province
			// 	this.city=option.city
			// 	this.tui_type=2
			// 	this.label2=this.city
			// }
			if(this.keywords!=''){
				this.tiezi()
			}

			// this.qiye_lebiao()
			// this.tuijian_shichang()
			// this.leixing_list()
			// this.jggy()
			// this.chanqu()
			// this.baozhuang()
			// this.qijylist()
			// this.qy_fl_list()
		},
		// onShow() {
		// 	this.user_page=1
		// 	this.user_list=[]
		// 	this.user_kk=false
		// 	this.user_enmpy=false
		// 	if(this.type==4){
		// 		this.user_cha()
		// 	}
		// 	this.cp_kk=false
		// 	this.cp_list=[]
		// 	this.cp_page=1
		// 	if(this.type==1){
		// 		this.tiezi(1)
		// 	}
		// },
		onReachBottom:function(){
			if(this.type==1){
				if(this.cp_enmpy){
					return
				}else{
					this.tiezi()
				}
			}else if(this.type==2){
				if(this.qiye_enmpy){
					return
				}else{
					this.qiye_lebiao()
				}
			}else if(this.type==3){
				if(this.qh_enmpy){
					return
				}else{
					this.qijylist()
				}
			}else if(this.type==4){
				if(this.user_enmpy){
					return
				}else{
					this.user_cha()
				}
			}
		},
		methods:{
			// 企业 推荐 分类
			qy_fl_list: function() {
				this.post('api/firm_data/category', '', true).then(res => {
					console.log(res, 123)
					if (res.code == 1) {
						this.yuan_list_arr6=res.data
						for (let i = 0; i < res.data.length; i++) {
							this.list_arr6.push(res.data[i].name)
						}
					}
				})
			},
			// 获取搜索历史
			sou_lishi:function(){
				this.post('api/index/history_search','',true).then(res=>{
					console.log(res)
					if(res.code==1){
						this.lishi_list=res.data
					}
				})
			},
			qingkong:function(){
				this.post('api/index/clear_history','',true).then(res=>{
					console.log(res)
					if(res.code==1){
						uni.showToast({
							title: res.msg,
							icon: "none",
							duration: 1000
						})
						this.lishi_list=[]
					}else{
						uni.showToast({
							title: res.msg,
							icon: "none",
							duration: 1000
						})
					}
				})
			},
			// 用户信息
			async yh_xx(id,type,f_id) {
				let isLogin = await this.$refs.noLoginToast.open()
				if (isLogin) {
					let isHasMobile = await this.$refs.noLoginToast.getPhoneNumber()
					if (!isHasMobile) {
						return
					}
				} else {
					return
				}
				if(type==1){
					uni.navigateTo({
						url:'../../../subpages/pages/wuliuqiye/wl_qyxq?id='+f_id
					})
				}else{
					uni.navigateTo({
						url: 'yhxx?id=' + id
					})
				}
			},
			yonghu_xx:function(id){
				uni.navigateTo({
					url:'yhxx?id='+id
				})
			},
			// 用戶查找
			user_cha:function(){
				let data={
					manage_id:this.manage_id,
					keywords:this.keywords,
					page:this.user_page,
					limit:10
				}
				this.post('api/client/search',data,true).then(res=>{
					if(res.code==1){
						if(this.user_page==1){
							if (res.data.data== null || res.data.data.length == 0) {
								this.user_kk = true
								this.user_enmpy = true
								return
							} else if (res.data.data.length < 10) {
								this.user_enmpy = true
							}
						}else{
							if (res.data.data== null || res.data.data.length == 0) {
								this.user_enmpy = true
								return
							} else if (res.data.data.length < 10) {
								this.user_enmpy = true
							}
						}

						this.user_page++
						this.user_list.push(...res.data.data)
					}else{
						this.user_kk = true
						uni.showToast({
							title: res.msg,
							icon: "none",
							duration: 1000
						})
					}
				})
			},
			// 经营范围
			fanwei:function(){
				uni.navigateTo({
					url:'user_fanwei?zhong1='+this.zhong1+'&zhong2='+this.zhong2+'&zhong3='+this.zhong3+'&id='+this.manage_id
				})
			},
			// 厂家详情
			changjia: function(id) {
				uni.navigateTo({
					url: 'cjxq?id=' + id
				})
			},
			qie:function(index){
				this.type=index
				if(this.type==1){
					this.category_id=''
					this.cp_page=1
					this.cp_list=[]
					this.cp_kk=false
					this.cp_enmpy=false
					this.tiezi()
				}else if(this.type==2){
					this.qihuo3=''
					this.province=''
					this.city=''
					this.qihuo5=''
					this.qihuo6=''
					this.value2=[]
					this.label2=''
					this.qiye_enmpy=false
					this.qiye_kk=false
					this.qiye_page=1
					this.qiye_list=[]
					this.leixing=''
					this.category_id=''
					this.bazaar_id=''
					this.tui_type=1
					this.qiye_lebiao()
				}else if(this.type==3){
					this.qihuo=''
					this.qihuo1=''
					this.qihuo2=''
					this.qh_enmpy=false
					this.qh_kk=false
					this.qhjy_list=[]
					this.qhjy_page=1
					this.craft_ids=''
					this.place_ids=''
					this.specification_ids=''
					this.manage_category_ids=''
					this.qi_type=1
					this.qijylist()
				}else if(this.type==4){
					this.user_page=1
					this.user_list=[]
					this.user_kk=false
					this.user_enmpy=false
					this.manage_id=''
					this.jyfw=''
					this.user_cha()
				}
			},
			jiage:function(index){
				this.tui_type=index
				if(index==2){
					this.$refs['picker6'].show()
				}else if(index==3){
					this.$refs['picker3'].show()
				}else if(index==4){
					this.$refs['picker5'].show()
				}else if(index==1){
					this.qihuo3=''
					this.province=''
					this.city=''
					this.qihuo5=''
					this.qihuo6=''
					this.value2=[]
					this.label2=''
					this.bazaar_id=''
					this.leixing=''
					this.category_id=''
					this.qiye_enmpy=false
					this.qiye_kk=false
					this.qiye_page=1
					this.qiye_list=[]
					this.qiye_lebiao()
				}else if(index==5){
					this.$refs['picker7'].show()
				}
			},
			// 期货价格
			qi_huo:function(index){
				this.qi_type=index
				if(index==2){
					this.$refs['picker'].show()
				}else if(index==3){
					this.$refs['picker1'].show()
				}else if(index==4){
					this.$refs['picker2'].show()
				}else if(index==1){
					this.qihuo=''
					this.qihuo1=''
					this.qihuo2=''
					this.qhjy_list=[]
					this.qhjy_page=1
					this.qh_enmpy=false
					this.qh_kk=false
					this.craft_ids=''
					this.place_ids=''
					this.specification_ids=''
					this.manage_category_ids=''
					this.qijylist()
				}
			},
		// 帖子
			// 帖子分类
			tz_fl:function(){
				this.post('api/index/voice_category','',true).then(res=>{
					console.log(res)
					if(res.code==1){
						let arr=[{
							name:'全部',
							id:'0'
						}]
						this.yuan_list=arr.concat(res.data)
						console.log(this.yuan_list)
						for(let i=0;i<this.yuan_list.length;i++){
							this.yuan_list[i]['ids']='a'+i
						}
					}
				})
			},
			ontabtap:function(index){
				this.tabIndex=index
				this.scrollInto = this.yuan_list[index].ids;
				this.cp_kk=false
				this.cp_enmpy=false
				this.cp_page=1
				this.cp_list=[]
				this.category_id=this.yuan_list[index].id
				this.tiezi()
			},
			// handleValueChange(currentVal) {
			// 	console.log(currentVal)
			// 	this.cp_kk=false
			// 	this.cp_enmpy=false
			// 	this.cp_page=1
			// 	this.cp_list=[]
			// 	this.category_id=this.yuan_list[currentVal.currentInd].id
			// 	this.tiezi()
			// },
			tiezi:function(click){
				if(this.keywords.replace(/\s*/g,"")==''){
					this.keywords=''
					this.xianshi=false
					this.cp_kk=false
					this.cp_enmpy=false
					this.cp_page=1
					this.cp_list=[]
					uni.showToast({
						title: '请输入要搜索的内容',
						icon: "none",
						duration: 1000
					})
					return
				}
				this.xianshi=true
				let data={
					voice_category_id:this.category_id,
					voice_manage_id:'',
					keywords:this.keywords,
					page:this.cp_page,
					limit:10
				}
				this.post('api/voice',data,true).then(res=>{
					if(res.code==1){
						if(this.cp_page==1){
							if (res.data.data== null || res.data.data.length == 0) {
								this.cp_kk = true
								this.cp_enmpy = true
								return
							} else if (res.data.data.length < 10) {
								this.cp_enmpy = true
							}else{
								this.cp_enmpy = false
							}
						}else{
							if (res.data.data== null || res.data.data.length == 0) {
								this.cp_enmpy = true
								return
							} else if (res.data.data.length < 10) {
								this.cp_enmpy = true
							}else{
								this.cp_enmpy = false
							}
						}

						this.cp_page++
						if (click == 1) {
							this.list = []
						}
						this.cp_list.push(...res.data.data)
						for(let i=0;i<this.cp_list.length;i++){
							this.cp_list[i].num=!this.cp_list[i].main_content.match(/\n/g)?0:this.cp_list[i].main_content.match(/\n/g).length
							if(this.cp_list[i].num>=4 || this.cp_list[i].main_content.length>=88 || (this.cp_list[i].num==3 && this.cp_list[i].main_content.length>=25) || (this.cp_list[i].num==2 && this.cp_list[i].main_content.length>=46) || (this.cp_list[i].num==1 && this.cp_list[i].main_content.length>=67)){
								this.cp_list[i].more_check=true
							}else{
								this.cp_list[i].more_check=false
							}
						}
					}else{
						this.cp_kk = true
						uni.showToast({
							title: res.msg,
							icon: "none",
							duration: 1000
						})
					}
				})
			},
			search() {
				if(this.type==1){
					this.cp_kk=false
					this.cp_enmpy=false
					this.cp_page=1
					this.cp_list=[]
					this.tiezi()
				}else if(this.type==2){
					this.qiye_kk=false
					this.qiye_enmpy=false
					this.qiye_page=1
					this.qiye_list=[]
					this.qiye_lebiao()
				}else if(this.type==3){
					this.qhjy_list=[]
					this.qhjy_page=1
					this.qh_enmpy=false
					this.qh_kk=false
					this.qijylist()
				}else if(this.type==4){
					this.user_page=1
					this.user_list=[]
					this.user_kk=false
					this.user_enmpy=false
					this.manage_id=''
					this.jyfw=''
					this.user_cha()
				}
			},
			sou_ls:function(index){
				this.keywords=index
				this.search()
			},
			// 帖子详情
			wzxq:function(id){
				uni.navigateTo({
					url:'wzxq?id='+id
				})
			},

		// 企业
			// 推荐市场
			handleConfirm3(e) {
				let that=this
				let index=e.index[0] || e.index
				console.log(index,123456)
				this.bazaar_id=this.yuan_list_arr3[index].id
				this.qiye_page=1
				this.qiye_list=[]
				this.qiye_enmpy=false
				this.qiye_kk=false
				this.qiye_lebiao()
			},
			handleConfirm4 (e) {
			  // 如果存在多个picker，可以在picker上设置dataset属性，confirm中获取，就能区分是哪个picker了
			  console.log('confirm::', e)
			  if (e) {
				  this.label2= e.item[1].label
			    // const name = e.dataset.name
			    // const label = e.item.map(m => m.label).join('-')
			    // if (name && label) {
			    //   this[name] = label
			    // }
			  }
			  this.province=e.item[0].label
			   this.city=e.item[1].label
			   this.qiye_page=1
			   this.qiye_list=[]
			   this.qiye_enmpy=false
			   this.qiye_kk=false
			   this.qiye_lebiao()
			},
			// 推荐市场
			handleConfirm5(e) {
				let that=this
				let index=e.index[0] || e.index
				console.log(index,123456)
				this.leixing=this.yuan_list_arr5[index].title
				console.log(this.yuan_list_arr5,1234567777)
				this.qiye_page=1
				this.qiye_list=[]
				this.qiye_enmpy=false
				this.qiye_kk=false
				this.qiye_lebiao()
			},
			handleConfirm6(e) {
				let that=this
				let index=e.index[0] || e.index
				console.log(index,123456)
				this.qihuo6=this.yuan_list_arr6[index].name
				this.category_id=this.yuan_list_arr6[index].id
				this.qiye_page=1
				this.qiye_list=[]
				this.qiye_enmpy=false
				this.qiye_kk=false
				this.qiye_lebiao()
			},
			// 推荐市场列表
			tuijian_shichang:function(){
				this.post('api/firm_data/bazaar','',true).then(res=>{
					console.log(res)
					if(res.code==1){
						this.yuan_list_arr3=res.data
						for(let i=0;i<res.data.length;i++){
							this.list_arr3.push(res.data[i].name)
						}
					}
				})
			},
			// 推荐类型列表
			leixing_list:function(){
				this.post('api/firm_data/get_type','',true).then(res=>{
					console.log(res)
					if(res.code==1){
						this.yuan_list_arr5=res.data
						for(let i=0;i<res.data.length;i++){
							this.list_arr5.push(res.data[i].title)
						}
					}
				})
			},
			// 企业列表
			qiye_lebiao:function(){
				let data={
					page:this.qiye_page,
					limit:10,
					type:this.leixing,
					province:this.province,
					city:this.city,
					bazaar_id:this.bazaar_id,
					keywords:this.keywords,
					manage_id:this.category_id
				}
				this.post('api/firm_data',data,true).then(res=>{
					console.log(res)
					if(res.code==1){
						if(this.qiye_page==1){
							if (res.data.data== null || res.data.data.length == 0) {
								this.qiye_kk = true
								this.qiye_enmpy = true
								return
							} else if (res.data.data.length < 10) {
								this.qiye_enmpy = true
							}
						}else{
							if (res.data.data== null || res.data.data.length == 0) {
								this.qiye_enmpy = true
								return
							} else if (res.data.data.length < 10) {
								this.qiye_enmpy = true
							}
						}

						this.qiye_page++
						this.qiye_list.push(...res.data.data)
						console.log(this.qiye_list,123456789)
					}else{
						this.qiye_kk = true
						uni.showToast({
							title: res.msg,
							icon: "none",
							duration: 1000
						})
					}
				})
			},
			// 企业详情
			qyxq:function(id,type){
				if(type==1){
					uni.navigateTo({
						url: 'qyxq?id=' + id
					})
				}else{
					uni.navigateTo({
						url:'../../../subpages/pages/wuliuqiye/wl_qyxq?id='+id
					})
				}
			},

		// 期货
			handleConfirm(e) {
				let that=this
				let index=e.index[0] || e.index
				console.log(index,123456)
				this.craft_ids=this.yuan_list_arr[index].id
				this.qhjy_page=1
				this.qhjy_list=[]
				this.qijylist()
			},
			handleConfirm1(e) {
				let that=this
				let index=e.index[0] || e.index
				console.log(index,123456)
				this.place_ids=this.yuan_list_arr1[index].id
				this.qhjy_page=1
				this.qhjy_list=[]
				this.qh_enmpy=false
				this.qh_kk=false
				this.qijylist()
			},
			handleConfirm2(e) {
				let that=this
				let index=e.index[0] || e.index
				console.log(index,123456)
				this.specification_ids=this.yuan_list_arr2[index].id
				this.qhjy_page=1
				this.qh_enmpy=false
				this.qh_kk=false
				this.qhjy_list=[]
				this.qijylist()
			},
			// 品牌规格
			jggy:function(){
				this.post('api/futures/craft','',true).then(res=>{
					console.log(res)
					if(res.code==1){
						this.yuan_list_arr=res.data
						for(let i=0;i<res.data.length;i++){
							this.list_arr.push(res.data[i].name)
						}
					}
				})
			},
			// 产区
			chanqu:function(){
				this.post('api/futures/place','',true).then(res=>{
					console.log(res)
					if(res.code==1){
						this.yuan_list_arr1=res.data
						for(let i=0;i<res.data.length;i++){
							this.list_arr1.push(res.data[i].name)
						}
					}
				})
			},
			// 包装
			baozhuang:function(){
				this.post('api/futures/specification','',true).then(res=>{
					console.log(res)
					if(res.code==1){
						this.yuan_list_arr2=res.data
						for(let i=0;i<res.data.length;i++){
							this.list_arr2.push(res.data[i].name)
						}
					}
				})
			},
			// 期货交易列表
			qijylist:function(){
				let data={
					page:this.qhjy_page,
					limit:10,
					craft_ids:this.craft_ids,
					place_ids:this.place_ids,
					specification_ids:this.specification_ids,
					manage_category_ids:this.manage_category_ids,
					brand_id:this.brand_id,
					keywords:this.keywords
				}
				this.post('api/futures',data,true).then(res=>{
					console.log(res)
					if(res.code==1){
						if(this.qhjy_page==1){
							if (res.data.data== null || res.data.data.length == 0) {
								this.qh_kk = true
								this.qh_enmpy = true
								return
							} else if (res.data.data.length < 10) {
								this.qh_enmpy = true
							}
						}else{
							if (res.data.data== null || res.data.data.length == 0) {
								this.qh_enmpy = true
								return
							} else if (res.data.data.length < 10) {
								this.qh_enmpy = true
							}
						}

						this.qhjy_page++
						this.qhjy_list.push(...res.data.data)
						console.log(this.qhjy_list,123456789)
					}else{
						this.qh_kk = true
						uni.showToast({
							title: res.msg,
							icon: "none",
							duration: 1000
						})
					}
				})
			},
			// 代采介绍
			dcjs:function(id){
				uni.navigateTo({
					url:'../../../subpages/pages/dcjs?id='+id
				})
			},
			userinfo:function(){
				this.post('api/client/info','',true).then(res=>{
					console.log(res)
					if(res.code==1){
						this.is_vip=res.data.is_vip
					}
				})
			},
			// 关注厂家
			gz_cj:function(id,index){
				this.post('api/futures/attention',{id:id},true).then(res=>{
					console.log(res)
					if(res.code==1){
						uni.showToast({
							title: res.msg,
							icon: "none",
							duration: 1000
						})
						if(res.data){
							this.qhjy_list[index].is_collect=1
						}else{
							this.qhjy_list[index].is_collect=2
						}
						if(this.qi==2){
							this.qhjy_list.splice(index,1)
							if(this.qhjy_list.length<=0){
								this.qh_kk=true
							}
						}
					}
				})
			},
			// 关注用户
			guanzhu:function(id,index){
				this.post('api/client/attention_client',{client_id:id},true).then(res=>{
					console.log(res)
					if(res.code==1){
						uni.showToast({
							title: res.msg,
							icon: "none",
							duration: 1000
						})
						if(res.data){
							this.user_list[index].is_attention=1
						}else{
							this.user_list[index].is_attention=0
						}
					}
				})
			},
			lahei:function(id,index){
				this.$refs.popup2.open()
				this.lh_id=id
				this.lh_index=index
			},
			// 不感兴趣
			bgxq:function(){
				this.$refs.popup2.close()
				this.cp_list.splice(this.lh_index,1)
				uni.showToast({
					icon:'none',
					title: '以后尽量减少此类内容的推送',
					duration: 2000
				});
			},
			// 拉黑作者
			lhftr:function(){
				let that=this
				this.$refs.popup2.close()
				uni.showModal({
					title: '确定拉黑该用户？',
					content: '拉黑后看不到此用户发的帖子，需要到黑名单解除！',
					success: function (res) {
						if (res.confirm) {
							that.post('api/client/black_client',{client_id:that.lh_id},true).then(res=>{
								console.log(res)
								if(res.code==1){
									uni.showToast({
										title: res.msg,
										icon: "none",
										duration: 1000
									})
									// that.list.splice(that.lh_index,1)
									that.cp_page=1
									// that.enmpy=false
									that.cp_kk=false
									that.cp_list=[]
									console.log(222222222)
									that.tiezi(1)
								}else{
									uni.showToast({
										title: res.msg,
										icon: "none",
										duration: 1000
									})
								}
							})
						} else if (res.cancel) {
							console.log('用户点击取消');
						}
					}
				});
			},
			lahei1:function(id,index){
				this.$refs.popup3.open()
				this.lh_id1=id
				this.lh_index1=index
			},
			// 不感兴趣
			bgxq1:function(){
				this.$refs.popup3.close()
				this.qiye_list.splice(this.lh_index1,1)
				uni.showToast({
					icon:'none',
					title: '以后尽量减少此类内容的推送',
					duration: 2000
				});
			},
			// 拉黑作者
			lhftr1:function(){
				let that=this
				this.$refs.popup3.close()
				uni.showModal({
					title: '确定拉黑该企业？',
					content: '拉黑后看不到此企业，需要到黑名单解除！',
					success: function (res) {
						if (res.confirm) {
							that.post('api/client/black_firm',{firm_id:that.lh_id1},true).then(res=>{
								console.log(res)
								if(res.code==1){
									uni.showToast({
										title: res.msg,
										icon: "none",
										duration: 1000
									})
									that.qiye_list.splice(that.lh_index1,1)
								}else{
									uni.showToast({
										title: res.msg,
										icon: "none",
										duration: 1000
									})
								}
							})
						} else if (res.cancel) {
							console.log('用户点击取消');
						}
					}
				});
			}
		}
	}
</script>

<style lang="scss">
	.xiao {
		color: #19BE6B;
		font-size: 20rpx;
		padding: 0rpx 10rpx;
		background: #f3f3f3;
		border-radius: 14rpx;
		display: inline-block;
		height: 30rpx;
		line-height: 30rpx;
		margin-right: 10rpx;
		margin-bottom: 10rpx;
		float: left;
	}
	page{
		background-color: #F8F8F8!important;
		font-family: Demibold;
	}
	.tuijian{
		display: flex;
		height: 80rpx;
		line-height: 80rpx;
		text-align: center;
		padding: 20rpx 0 10rpx;
		// justify-content:space-between;
	}
	.tuijian>view{
		flex: 1;
		position: relative;
	}
	.active_type{
		color: #FFFFFF;
		font-size: 40rpx;
		font-weight: 600;
	}
	.a_type{
		color: #FFFFFF;
		font-size: 26rpx;
		font-weight: 500;
	}
	.active_type::after {
	     content: ''; // 必须
	     position: absolute;
	     left: 50%;
	     bottom: 0;
		 transform: translateX(-50%);
	     width: 60rpx;
	     height: 6rpx;
	     background-color: #FFFFFF;
	}
	.sou {
		width: 100%;
		height: 80rpx;
		line-height: 80rpx;
		border-radius: 40rpx;
		color: #FFFFFF;
		font-size: 26rpx;
		box-sizing: border-box;
		padding: 0 30rpx 0 80rpx;
		background-color: rgba(255,255,255,.3);
	}
	.tu>view {
		margin: 10rpx 0;
	}

	.tu>view:nth-child(3n+2) {
		margin: 10rpx 30rpx;
	}
	.suo {
		color: #FFFFFF;
		opacity: 1;
		font-size: 26rpx;
	}

	.souicon {
		width: 30rpx;
		height: 30rpx;
		position: absolute;
		top: 50%;
		left: 30rpx;
		transform: translateY(-50%);

	}
	.tui_mei{
		color: #666666;
		font-size: 28rpx;
		font-weight: 500;
	}
	.tui_active{
		color: #000000;
		font-size: 28rpx;
		font-weight: 600;
	}
	.scroll-h {
	    width: 100%;
		margin: 0 auto;
	    height: 80rpx;
		line-height: 80rpx;
	    flex-direction: row;
	    /* #ifndef APP-PLUS */
	    white-space: nowrap;
	    /* #endif */
	    /* flex-wrap: nowrap; */
	    /* border-color: #cccccc;
		border-bottom-style: solid;
		border-bottom-width: 1px; */
	}

	.uni-tab-item {
	    /* #ifndef APP-PLUS */
	    display: inline-block;
	    /* #endif */
	    flex-wrap: nowrap;
		/* float: left; */
	    padding-left: 30rpx;
	    padding-right: 30rpx;
		position: relative;
		 display: inline-block;
	}
	.uni-tab-item:after{

	}
	.uni-tab-item:first-child:after{
		background: none;
	}
	.uni-tab-item-title {
	    height: 80rpx;
	    line-height: 80rpx;
	    flex-wrap: nowrap;
		font-size: 30rpx;
		color: #666;
	    /* #ifndef APP-PLUS */
	    white-space: nowrap;
	    /* #endif */
	}

	.uni-tab-item-title-active {
	    font-weight: 600;
	    font-size: 30rpx;
		color: #000;
	}
</style>
